Skip to content

Conversation

@austin3dickey
Copy link
Contributor

@austin3dickey austin3dickey commented Nov 21, 2025

Addresses #10423. Adds the ms-python.vscode-python-envs extension to the list of incompatible Positron extensions.

I also noticed that it was still getting installed as a recursive dependency of other extensions like Pyrefly. So this PR also adds some code that checks for compatibility of recursive dependencies before installing them. In order to do that, I had to move some stuff from the workbench level to the platform level.

Release Notes

New Features

  • N/A

Bug Fixes

  • Stop the Python Environments Extension from being installed because it conflicts with internal features. You may want to uninstall this extension if it's installed already.

QA Notes

The python environments extension shouldn't be installable directly or as a dependency of e.g. pyrefly or ty.

If you had it before, it won't delete it.

@ Julia: add a release note reminding users to uninstall this extension.

@github-actions
Copy link

github-actions bot commented Nov 21, 2025

E2E Tests 🚀
This PR will run tests tagged with: @:critical

readme  valid tags

This comment was marked as resolved.

}
// --- End Positron ---
const manifest = await this.extensionGalleryService.getManifest(gallery, CancellationToken.None);
if (!manifest) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This strange formatting must have been left over from an upstream merge or something.

'vscode.r',
'jeanp413.open-remote-ssh',
'ms-python.python',
'ms-python.vscode-python-envs',
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This new code won't delete these extensions if you already had them. Should we go that far? (making sure we don't delete builtin ones like our version of ms-python.python of course)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still think deleting them is very aggressive, since we can't know if we installed anything here or if the user did. I think the best option is a notification like in #10712.

juliasilge
juliasilge previously approved these changes Nov 21, 2025
Copy link
Contributor

@juliasilge juliasilge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is working for me. If I totally blow away all state and extensions I have ever installed previously, I do not see the problematic extension installed and I only see the ones on our list:

Image

I see the expected error if I try to install ms-python.vscode-python-envs directly.

I am not super familiar with this part of the code base, but the changes look reasonable to me! 🚀

'jeanp413.open-remote-ssh',
'ms-python.python',
'ms-python.vscode-python-envs',
'GitHub.copilot-chat'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
'GitHub.copilot-chat'
'github.copilot-chat'

isPositronExtensionCompatible converts extension IDs to lowercase before comparison, maybe we should include in the function comment that these need to be all lower case?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

great catch!!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cool, fixed, interestingly this bug was present before too!

Copy link
Contributor

@melissa-barca melissa-barca left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@austin3dickey austin3dickey merged commit e8a64ac into main Nov 24, 2025
11 of 12 checks passed
@austin3dickey austin3dickey deleted the aus/stop-envs branch November 24, 2025 21:10
@github-actions github-actions bot locked and limited conversation to collaborators Nov 24, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants